package com.wc.blue_bridge_test.base.T7;

import java.util.Scanner;

/**
 * @Author congege
 * @Description 字母图形
 * https://lx.lanqiao.cn/problem.page?gpid=T7
 * @Date Created in 2023/12/24-12:10
 */
public class Main {
    static char[][] map;
    static int n, m;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        n = sc.nextInt();
        m = sc.nextInt();
        map = new char[n][m];
        for (int i = 0; i < m; i++) {
            put(0, i, (char) (i + 'A'));
        }
        for (int i = 1; i < n; i++) {
            put(i, 0, (char) (i + 'A'));
        }
        for (int i = 0; i < n; i++) {
            System.out.println(new String(map[i]));
        }
    }

    public static void put(int x, int y, char letter) {
        while (!isBorder(x, y)) {
            map[x][y] = letter;
            x++;
            y++;
        }
    }

    public static boolean isBorder(int x, int y) {
        return x < 0 || x == n || y < 0 || y == m;
    }
}
